using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Navigation;
using Microsoft.Phone.Controls;
using Microsoft.Phone.Shell;
using Microsoft.Phone.Tasks;

namespace LyonMag
{
    public partial class Socail : PhoneApplicationPage
    {
        public Socail()
        {
            InitializeComponent();
        }

        private void stkWebsite_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            WebBrowserTask wb = new WebBrowserTask();
            wb.Uri=new Uri("http://www.lyonmag.com/");
            wb.Show();
        }

        private void stkRate_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            MarketplaceReviewTask obj_Review = new MarketplaceReviewTask();
            obj_Review.Show();
        }

        private void stlfacebookPage_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            WebBrowserTask wb = new WebBrowserTask();
            wb.Uri = new Uri("http://www.facebook.com/lyonmag", UriKind.Absolute);
            wb.Show();
        }

        private void stkTwitterPage_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
             WebBrowserTask wb = new WebBrowserTask();
            wb.Uri = new Uri("https://twitter.com/lyonmag", UriKind.Absolute);
            wb.Show();

        }

        private void stkWebsite_Tap_1(object sender, System.Windows.Input.GestureEventArgs e)
        {

        }

        private void stkEmail_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            EmailComposeTask obj_Email = new EmailComposeTask();
            obj_Email.Subject = "Télécharger l'application Lyon Ma";
            obj_Email.Body = "Télécharge l’application Lyon Mag Windows Phone gratuitement";
            obj_Email.Show();
        }

        private void stkfacebook_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            try
            {
                ShareLinkTask obj_share = new ShareLinkTask();
                obj_share.Message = "lyonmag";
                obj_share.Title = "lyonmag";
                obj_share.LinkUri = new Uri("http://www.lyonmag.com");
                obj_share.Show();
            }
            catch (Exception ex)
            {
                ex.Message.ToString();
            }
        }

        private void stkTwitter_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            try
            {
                ShareLinkTask obj_share = new ShareLinkTask();
                obj_share.Message = "lyonmag";
                obj_share.Title = "lyonmag";
                obj_share.LinkUri = new Uri("http://www.lyonmag.com");
                obj_share.Show();
            }
            catch (Exception ex)
            {
                ex.Message.ToString();
            }
        }

        private void stkPoll_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            NavigationService.Navigate(new Uri("/Poll.xaml", UriKind.RelativeOrAbsolute));
        }
    }
}